import { IsNumber, IsOptional } from 'class-validator';
import { ApiProperty } from '@nestjs/swagger';

export class QueryCommentDto {
  @ApiProperty({ description: '页码', required: false, default: 1 })
  @IsNumber()
  @IsOptional()
  pageNum?: number = 1;

  @ApiProperty({ description: '每页数量', required: false, default: 10 })
  @IsNumber()
  @IsOptional()
  pageSize?: number = 10;

  @ApiProperty({ description: '商品ID', required: false })
  @IsNumber()
  @IsOptional()
  goodsId?: number;

  @ApiProperty({ description: '用户ID', required: false })
  @IsNumber()
  @IsOptional()
  userId?: number;
}
